package com.example.demo.service.assembler;

import com.example.demo.api.Dto.EmployeeDto;
import com.example.demo.domain.entity.Employee;

public class EmployeeAssembler {

    private EmployeeAssembler() {

    }

    public static Employee toEmployee(EmployeeDto employeeDTO) {
        Employee employee = new Employee();
        employee.setEmployeeId(employeeDTO.getEmployeeId());
        employee.setFirstName(employeeDTO.getFirstName());
        employee.setLastName(employeeDTO.getLastName());
        employee.setSalary(employeeDTO.getSalary());
        employee.setEmail(employeeDTO.getEmail());
        return employee;
    }
}
